import { Injectable } from '@angular/core';
import {RequestUtil} from "../../../util/request-util";
import {Observable} from "rxjs/Observable";
import {MsgResult} from "../../../models/msg-result";
import {API} from "../../../constants/constants";

@Injectable()
export class AccountStatService {

  constructor(
    private requestUtil: RequestUtil
  ) { }

  getStatisticsDailyVisitsByTime():Observable<MsgResult>{
    let params = 'startTime='+null;
    return this.requestUtil.post(API.getStatisticsDailyVisitsByTime,params);
  }

  getStatisticsVisitsByTime(params:string):Observable<MsgResult>{
    return this.requestUtil.post(API.getStatisticsVisitsByTime,params);
  }

  getNewAccountByTime(params:string):Observable<MsgResult>{
    return this.requestUtil.post(API.getNewAccountByTime,params);
  }


  getVisitNumber(params:string):Observable<MsgResult>{
    return this.requestUtil.post(API.getVisitNumber,params);
  }
  getTerminalVisitType():Observable<MsgResult>{
    return this.requestUtil.post(API.getTerminalVisitType);
  }


}
